package cy.pj.common.util;

import com.github.pagehelper.Page;
import com.github.pagehelper.PageHelper;

public class PageUtil {
    public static <T>Page<T> startPage(){
        String pageSizeStr=null;
        String pageCurrentStr=null;
        System.out.println("pagesize="+pageSizeStr);
        System.out.println("pagecurrentt="+pageCurrentStr);
        Integer pageCurrent =
                pageCurrentStr==null||"".equals(pageCurrentStr)?1:Integer.parseInt(pageCurrentStr);
        Integer pageSize =
                StringUtil.isEmpty(pageSizeStr)?10:Integer.parseInt(pageSizeStr);

        return PageHelper.startPage(pageCurrent,pageSize);
    }
}
